package com.example.lib_mvp.adapter;

import android.widget.CheckBox;

import androidx.annotation.NonNull;
import androidx.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.example.lib_mvp.beans.HdTransDocxBean;
import com.example.lib_mvp.R;

import java.util.List;

/**
 * 同声传译
 */
public class TransFaceLangAdapter extends BaseQuickAdapter<HdTransDocxBean.DataDTO, BaseViewHolder> {


    public TransFaceLangAdapter(int layoutResId, @Nullable List<HdTransDocxBean.DataDTO> data) {
        super(layoutResId, data);

    }

    @Override
    protected void convert(@NonNull BaseViewHolder holder, HdTransDocxBean.DataDTO item) {
        CheckBox pop_lang_check_read_box = holder.getView(R.id.pop_lang_check_read_box);
        pop_lang_check_read_box.setChecked(item.isSelect());
        holder.setText(R.id.pop_lang_gq_tv, item.getFlag());
//        holder.setText(R.id.pop_lang_tv, item.getName() + "(" + item.getLanguage() + ")");
        holder.setText(R.id.pop_lang_tv, item.getName());

    }
}
